﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

namespace Kokomo.Mirror.CliMetadata
{
	public struct BlobRef
	{
		public readonly int HeapIndex;
		public BlobRef(
			int heapIndex
			)
		{
			this.HeapIndex = heapIndex;
		}

		public bool IsNull { get { return this.HeapIndex == 0; } }

		//public override string ToString()
		//{
		//    int byteCount = Math.Min(16, this.Data.Length);
		//    StringBuilder builder = new StringBuilder(12 + byteCount * 3);
		//    builder.AppendFormat("[0x{0:X8}]", this.HeapIndex);
		//    for (int i = 0; i < byteCount; i++)
		//    {
		//        builder.AppendFormat(" {0:X2}", this.Data[i]);
		//    }

		//    return builder.ToString();
		//}
	}
}
